<!-- HTML header for doxygen 1.8.3.1-->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.3.1"/>
<title>Sifteo SDK: event.h Source File</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
<link href="doxygen-style-overrides.css" rel="stylesheet" type="text/css"/>
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<center>
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Sifteo SDK" src="sdk_logo.png"/></td>
  <td style="padding-left: 0.5em;">
   <div id="projectname">
   &#160;<span id="projectnumber">v1.0.0</span>
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
</center>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.3.1 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Home</span></a></li>
      <li><a href="pages.html"><span>Guides</span></a></li>
      <li><a href="modules.html"><span>Modules</span></a></li>
      <li><a href="annotated.html"><span>Reference</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
    </ul>
  </div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Namespaces</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Typedefs</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Enumerations</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&#160;</span>Enumerator</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&#160;</span>Groups</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(9)"><span class="SelectionMark">&#160;</span>Pages</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div id="nav-path" class="navpath">
  <ul>
<li class="navelem"><a class="el" href="dir_12cda917fe1d7c8b4e7d2501bb3636e4.html">sdk</a></li><li class="navelem"><a class="el" href="dir_2f23e30b638d6a5f333babd9a5d183e1.html">include</a></li><li class="navelem"><a class="el" href="dir_d5ace589187da7c83c1a7507ec9fbbef.html">sifteo</a></li>  </ul>
</div>
</div><!-- top -->
<div class="header">
  <div class="headertitle">
<div class="title">event.h</div>  </div>
</div><!--header-->
<div class="contents">
<div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno">    1</span>&#160;<span class="comment">/* -*- mode: C; c-basic-offset: 4; intent-tabs-mode: nil -*-</span></div>
<div class="line"><a name="l00002"></a><span class="lineno">    2</span>&#160;<span class="comment"> *</span></div>
<div class="line"><a name="l00003"></a><span class="lineno">    3</span>&#160;<span class="comment"> * This file is part of the public interface to the Sifteo SDK.</span></div>
<div class="line"><a name="l00004"></a><span class="lineno">    4</span>&#160;<span class="comment"> * Copyright &lt;c&gt; 2012 Sifteo, Inc. All rights reserved.</span></div>
<div class="line"><a name="l00005"></a><span class="lineno">    5</span>&#160;<span class="comment"> */</span></div>
<div class="line"><a name="l00006"></a><span class="lineno">    6</span>&#160;</div>
<div class="line"><a name="l00007"></a><span class="lineno">    7</span>&#160;<span class="preprocessor">#pragma once</span></div>
<div class="line"><a name="l00008"></a><span class="lineno">    8</span>&#160;<span class="preprocessor"></span><span class="preprocessor">#ifdef NOT_USERSPACE</span></div>
<div class="line"><a name="l00009"></a><span class="lineno">    9</span>&#160;<span class="preprocessor"></span><span class="preprocessor">#   error This is a userspace-only header, not allowed by the current build.</span></div>
<div class="line"><a name="l00010"></a><span class="lineno">   10</span>&#160;<span class="preprocessor"></span><span class="preprocessor">#endif</span></div>
<div class="line"><a name="l00011"></a><span class="lineno">   11</span>&#160;<span class="preprocessor"></span></div>
<div class="line"><a name="l00012"></a><span class="lineno">   12</span>&#160;<span class="preprocessor">#include &lt;sifteo/abi.h&gt;</span></div>
<div class="line"><a name="l00013"></a><span class="lineno">   13</span>&#160;</div>
<div class="line"><a name="l00014"></a><span class="lineno">   14</span>&#160;<span class="keyword">namespace </span>Sifteo {</div>
<div class="line"><a name="l00015"></a><span class="lineno">   15</span>&#160;</div>
<div class="line"><a name="l00016"></a><span class="lineno">   16</span>&#160;</div>
<div class="line"><a name="l00036"></a><span class="lineno">   36</span>&#160;<span class="keyword">template</span> &lt;_SYSVectorID tID&gt;</div>
<div class="line"><a name="l00037"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_event_vector.html">   37</a></span>&#160;<span class="keyword">struct </span><a class="code" href="struct_sifteo_1_1_event_vector.html" title="Implementation for a single event vector.">EventVector</a> {</div>
<div class="line"><a name="l00038"></a><span class="lineno">   38</span>&#160;    <a class="code" href="struct_sifteo_1_1_event_vector.html" title="Implementation for a single event vector.">EventVector</a>() {}</div>
<div class="line"><a name="l00039"></a><span class="lineno">   39</span>&#160;</div>
<div class="line"><a name="l00047"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_event_vector.html#a2929708f992ccd44af7ee5941bdd0940">   47</a></span>&#160;    <span class="keywordtype">void</span> <a class="code" href="struct_sifteo_1_1_event_vector.html#a2929708f992ccd44af7ee5941bdd0940" title="Disable this event vector.">unset</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00048"></a><span class="lineno">   48</span>&#160;        _SYS_setVector(tID, 0, 0);</div>
<div class="line"><a name="l00049"></a><span class="lineno">   49</span>&#160;    }</div>
<div class="line"><a name="l00050"></a><span class="lineno">   50</span>&#160;</div>
<div class="line"><a name="l00063"></a><span class="lineno">   63</span>&#160;    <span class="keyword">template</span> &lt;<span class="keyword">typename</span> tContext&gt;</div>
<div class="line"><a name="l00064"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_event_vector.html#a5de5ca0cfaf3f199b67f882cf9824ed1">   64</a></span>&#160;    <span class="keywordtype">void</span> <span class="keyword">set</span>(void (*<a class="code" href="struct_sifteo_1_1_event_vector.html#a80f21f1bc450ffa570ac42efb44f17b2" title="Return the currently set handler function, as a void pointer.">handler</a>)(tContext, unsigned), tContext <a class="code" href="struct_sifteo_1_1_event_vector.html#a5f0e96ff2a98a076436d2ad51dfef108" title="Return the currently set context object, as a void pointer.">context</a>)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00065"></a><span class="lineno">   65</span>&#160;        _SYS_setVector(tID, (<span class="keywordtype">void</span>*) <a class="code" href="struct_sifteo_1_1_event_vector.html#a80f21f1bc450ffa570ac42efb44f17b2" title="Return the currently set handler function, as a void pointer.">handler</a>, reinterpret_cast&lt;void*&gt;(context));</div>
<div class="line"><a name="l00066"></a><span class="lineno">   66</span>&#160;    }</div>
<div class="line"><a name="l00067"></a><span class="lineno">   67</span>&#160;</div>
<div class="line"><a name="l00080"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_event_vector.html#a8fe0367d9411589958dfc3eedf6a126c">   80</a></span>&#160;    <span class="keywordtype">void</span> <span class="keyword">set</span>(void (*<a class="code" href="struct_sifteo_1_1_event_vector.html#a80f21f1bc450ffa570ac42efb44f17b2" title="Return the currently set handler function, as a void pointer.">handler</a>)(<span class="keywordtype">void</span>*, unsigned))<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00081"></a><span class="lineno">   81</span>&#160;        _SYS_setVector(tID, (<span class="keywordtype">void</span>*) <a class="code" href="struct_sifteo_1_1_event_vector.html#a80f21f1bc450ffa570ac42efb44f17b2" title="Return the currently set handler function, as a void pointer.">handler</a>, 0);</div>
<div class="line"><a name="l00082"></a><span class="lineno">   82</span>&#160;    }</div>
<div class="line"><a name="l00083"></a><span class="lineno">   83</span>&#160;</div>
<div class="line"><a name="l00088"></a><span class="lineno">   88</span>&#160;    <span class="keyword">template</span> &lt;<span class="keyword">typename</span> tClass&gt;</div>
<div class="line"><a name="l00089"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_event_vector.html#a0a513fd4894ad481f8ec3997d8f1afc6">   89</a></span>&#160;    <span class="keywordtype">void</span> <span class="keyword">set</span>(void (tClass::*<a class="code" href="struct_sifteo_1_1_event_vector.html#a80f21f1bc450ffa570ac42efb44f17b2" title="Return the currently set handler function, as a void pointer.">handler</a>)(unsigned), tClass *cls)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00090"></a><span class="lineno">   90</span>&#160;        <span class="keyword">union </span>{</div>
<div class="line"><a name="l00091"></a><span class="lineno">   91</span>&#160;            <span class="keywordtype">void</span> *pVoid;</div>
<div class="line"><a name="l00092"></a><span class="lineno">   92</span>&#160;            void (tClass::*pMethod)(unsigned);</div>
<div class="line"><a name="l00093"></a><span class="lineno">   93</span>&#160;        } u;</div>
<div class="line"><a name="l00094"></a><span class="lineno">   94</span>&#160;        u.pMethod = <a class="code" href="struct_sifteo_1_1_event_vector.html#a80f21f1bc450ffa570ac42efb44f17b2" title="Return the currently set handler function, as a void pointer.">handler</a>;</div>
<div class="line"><a name="l00095"></a><span class="lineno">   95</span>&#160;        _SYS_setVector(tID, u.pVoid, (<span class="keywordtype">void</span>*) cls);</div>
<div class="line"><a name="l00096"></a><span class="lineno">   96</span>&#160;    }</div>
<div class="line"><a name="l00097"></a><span class="lineno">   97</span>&#160;</div>
<div class="line"><a name="l00101"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_event_vector.html#a80f21f1bc450ffa570ac42efb44f17b2">  101</a></span>&#160;    <span class="keywordtype">void</span> *<a class="code" href="struct_sifteo_1_1_event_vector.html#a80f21f1bc450ffa570ac42efb44f17b2" title="Return the currently set handler function, as a void pointer.">handler</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00102"></a><span class="lineno">  102</span>&#160;        <span class="keywordflow">return</span> _SYS_getVectorHandler(tID);</div>
<div class="line"><a name="l00103"></a><span class="lineno">  103</span>&#160;    }</div>
<div class="line"><a name="l00104"></a><span class="lineno">  104</span>&#160;</div>
<div class="line"><a name="l00108"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_event_vector.html#a5f0e96ff2a98a076436d2ad51dfef108">  108</a></span>&#160;    <span class="keywordtype">void</span> *<a class="code" href="struct_sifteo_1_1_event_vector.html#a5f0e96ff2a98a076436d2ad51dfef108" title="Return the currently set context object, as a void pointer.">context</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00109"></a><span class="lineno">  109</span>&#160;        <span class="keywordflow">return</span> _SYS_getVectorContext(tID);</div>
<div class="line"><a name="l00110"></a><span class="lineno">  110</span>&#160;    }</div>
<div class="line"><a name="l00111"></a><span class="lineno">  111</span>&#160;};</div>
<div class="line"><a name="l00112"></a><span class="lineno">  112</span>&#160;</div>
<div class="line"><a name="l00113"></a><span class="lineno">  113</span>&#160;</div>
<div class="line"><a name="l00121"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html">  121</a></span>&#160;<span class="keyword">struct </span><a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html" title="Implementation for the gameMenu event vector.">GameMenuEventVector</a> {</div>
<div class="line"><a name="l00122"></a><span class="lineno">  122</span>&#160;    <a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html" title="Implementation for the gameMenu event vector.">GameMenuEventVector</a>() {}</div>
<div class="line"><a name="l00123"></a><span class="lineno">  123</span>&#160;</div>
<div class="line"><a name="l00129"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#abdc720ab07e1238d16428db82b068974">  129</a></span>&#160;    <span class="keywordtype">void</span> <a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#abdc720ab07e1238d16428db82b068974" title="Disable this event vector, and disable the game menu.">unset</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00130"></a><span class="lineno">  130</span>&#160;        _SYS_setGameMenuLabel(0);</div>
<div class="line"><a name="l00131"></a><span class="lineno">  131</span>&#160;        _SYS_setVector(_SYS_BASE_GAME_MENU, 0, 0);</div>
<div class="line"><a name="l00132"></a><span class="lineno">  132</span>&#160;    }</div>
<div class="line"><a name="l00133"></a><span class="lineno">  133</span>&#160;</div>
<div class="line"><a name="l00145"></a><span class="lineno">  145</span>&#160;    <span class="keyword">template</span> &lt;<span class="keyword">typename</span> tContext&gt;</div>
<div class="line"><a name="l00146"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#a5ff40ce12765a1a125fe5e76b1a3844b">  146</a></span>&#160;    <span class="keywordtype">void</span> <span class="keyword">set</span>(void (*<a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#afa0b031f70803698ab096ba0df30dbe9" title="Return the currently set handler function, as a void pointer.">handler</a>)(tContext), tContext <a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#a325c6633309e4b141ab0fa0d2a463942" title="Return the currently set context object, as a void pointer.">context</a>, <span class="keyword">const</span> <span class="keywordtype">char</span> *label=0)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00147"></a><span class="lineno">  147</span>&#160;        <span class="keywordflow">if</span> (label)</div>
<div class="line"><a name="l00148"></a><span class="lineno">  148</span>&#160;            _SYS_setGameMenuLabel(label);</div>
<div class="line"><a name="l00149"></a><span class="lineno">  149</span>&#160;        _SYS_setVector(_SYS_BASE_GAME_MENU, (<span class="keywordtype">void</span>*) <a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#afa0b031f70803698ab096ba0df30dbe9" title="Return the currently set handler function, as a void pointer.">handler</a>, reinterpret_cast&lt;void*&gt;(context));</div>
<div class="line"><a name="l00150"></a><span class="lineno">  150</span>&#160;    }</div>
<div class="line"><a name="l00151"></a><span class="lineno">  151</span>&#160;</div>
<div class="line"><a name="l00163"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#a8d56183134a0a3807fdea34dcd1e1ea2">  163</a></span>&#160;    <span class="keywordtype">void</span> <span class="keyword">set</span>(void (*<a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#afa0b031f70803698ab096ba0df30dbe9" title="Return the currently set handler function, as a void pointer.">handler</a>)(<span class="keywordtype">void</span>*), <span class="keyword">const</span> <span class="keywordtype">char</span> *label=0)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00164"></a><span class="lineno">  164</span>&#160;        <span class="keywordflow">if</span> (label)</div>
<div class="line"><a name="l00165"></a><span class="lineno">  165</span>&#160;            _SYS_setGameMenuLabel(label);</div>
<div class="line"><a name="l00166"></a><span class="lineno">  166</span>&#160;        _SYS_setVector(_SYS_BASE_GAME_MENU, (<span class="keywordtype">void</span>*) <a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#afa0b031f70803698ab096ba0df30dbe9" title="Return the currently set handler function, as a void pointer.">handler</a>, 0);</div>
<div class="line"><a name="l00167"></a><span class="lineno">  167</span>&#160;    }</div>
<div class="line"><a name="l00168"></a><span class="lineno">  168</span>&#160;</div>
<div class="line"><a name="l00176"></a><span class="lineno">  176</span>&#160;    <span class="keyword">template</span> &lt;<span class="keyword">typename</span> tClass&gt;</div>
<div class="line"><a name="l00177"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#a3d3758805b884a4fd17d9ebdddce4f66">  177</a></span>&#160;    <span class="keywordtype">void</span> <span class="keyword">set</span>(void (tClass::*<a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#afa0b031f70803698ab096ba0df30dbe9" title="Return the currently set handler function, as a void pointer.">handler</a>)(), tClass *cls, <span class="keyword">const</span> <span class="keywordtype">char</span> *label=0)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00178"></a><span class="lineno">  178</span>&#160;        <span class="keyword">union </span>{</div>
<div class="line"><a name="l00179"></a><span class="lineno">  179</span>&#160;            <span class="keywordtype">void</span> *pVoid;</div>
<div class="line"><a name="l00180"></a><span class="lineno">  180</span>&#160;            void (tClass::*pMethod)();</div>
<div class="line"><a name="l00181"></a><span class="lineno">  181</span>&#160;        } u;</div>
<div class="line"><a name="l00182"></a><span class="lineno">  182</span>&#160;        u.pMethod = <a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#afa0b031f70803698ab096ba0df30dbe9" title="Return the currently set handler function, as a void pointer.">handler</a>;</div>
<div class="line"><a name="l00183"></a><span class="lineno">  183</span>&#160;        <span class="keywordflow">if</span> (label)</div>
<div class="line"><a name="l00184"></a><span class="lineno">  184</span>&#160;            _SYS_setGameMenuLabel(label);</div>
<div class="line"><a name="l00185"></a><span class="lineno">  185</span>&#160;        _SYS_setVector(_SYS_BASE_GAME_MENU, u.pVoid, (<span class="keywordtype">void</span>*) cls);</div>
<div class="line"><a name="l00186"></a><span class="lineno">  186</span>&#160;    }</div>
<div class="line"><a name="l00187"></a><span class="lineno">  187</span>&#160;</div>
<div class="line"><a name="l00191"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#afa0b031f70803698ab096ba0df30dbe9">  191</a></span>&#160;    <span class="keywordtype">void</span> *<a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#afa0b031f70803698ab096ba0df30dbe9" title="Return the currently set handler function, as a void pointer.">handler</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00192"></a><span class="lineno">  192</span>&#160;        <span class="keywordflow">return</span> _SYS_getVectorHandler(_SYS_BASE_GAME_MENU);</div>
<div class="line"><a name="l00193"></a><span class="lineno">  193</span>&#160;    }</div>
<div class="line"><a name="l00194"></a><span class="lineno">  194</span>&#160;</div>
<div class="line"><a name="l00198"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#a325c6633309e4b141ab0fa0d2a463942">  198</a></span>&#160;    <span class="keywordtype">void</span> *<a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#a325c6633309e4b141ab0fa0d2a463942" title="Return the currently set context object, as a void pointer.">context</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00199"></a><span class="lineno">  199</span>&#160;        <span class="keywordflow">return</span> _SYS_getVectorContext(_SYS_BASE_GAME_MENU);</div>
<div class="line"><a name="l00200"></a><span class="lineno">  200</span>&#160;    }</div>
<div class="line"><a name="l00201"></a><span class="lineno">  201</span>&#160;</div>
<div class="line"><a name="l00213"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#ab92e2bea24e03107cf8e52bf365a4dfd">  213</a></span>&#160;    <span class="keywordtype">void</span> <a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html#ab92e2bea24e03107cf8e52bf365a4dfd" title="Set the label text used for the Game Menu item.">setLabel</a>(<span class="keyword">const</span> <span class="keywordtype">char</span> *label)</div>
<div class="line"><a name="l00214"></a><span class="lineno">  214</span>&#160;    {</div>
<div class="line"><a name="l00215"></a><span class="lineno">  215</span>&#160;        <a class="code" href="group__macros.html#ga8a15779356736a0900a162442b1cda53" title="Runtime debug assertion.">ASSERT</a>(label &amp;&amp; label[0]);</div>
<div class="line"><a name="l00216"></a><span class="lineno">  216</span>&#160;        _SYS_setGameMenuLabel(label);</div>
<div class="line"><a name="l00217"></a><span class="lineno">  217</span>&#160;    }</div>
<div class="line"><a name="l00218"></a><span class="lineno">  218</span>&#160;};</div>
<div class="line"><a name="l00219"></a><span class="lineno">  219</span>&#160;</div>
<div class="line"><a name="l00220"></a><span class="lineno">  220</span>&#160;</div>
<div class="line"><a name="l00228"></a><span class="lineno">  228</span>&#160;<span class="keyword">template</span> &lt;_SYSVectorID tID&gt;</div>
<div class="line"><a name="l00229"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html">  229</a></span>&#160;<span class="keyword">struct </span><a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html" title="Implementation for a single neighbor event vector.">NeighborEventVector</a> {</div>
<div class="line"><a name="l00230"></a><span class="lineno">  230</span>&#160;    <a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html" title="Implementation for a single neighbor event vector.">NeighborEventVector</a>() {}</div>
<div class="line"><a name="l00231"></a><span class="lineno">  231</span>&#160;</div>
<div class="line"><a name="l00239"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#a9a20d1e55414d0ccc3df4a1739bb919f">  239</a></span>&#160;    <span class="keywordtype">void</span> <a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#a9a20d1e55414d0ccc3df4a1739bb919f" title="Disable this event vector.">unset</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00240"></a><span class="lineno">  240</span>&#160;        _SYS_setVector(tID, 0, 0);</div>
<div class="line"><a name="l00241"></a><span class="lineno">  241</span>&#160;    }</div>
<div class="line"><a name="l00242"></a><span class="lineno">  242</span>&#160;</div>
<div class="line"><a name="l00255"></a><span class="lineno">  255</span>&#160;    <span class="keyword">template</span> &lt;<span class="keyword">typename</span> tContext&gt;</div>
<div class="line"><a name="l00256"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#a3cdaec017c6d8efe7ecef6944e4c30a0">  256</a></span>&#160;    <span class="keywordtype">void</span> <span class="keyword">set</span>(void (*<a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#aaf7df5ac967817e954a0338ca9ac4f49" title="Return the currently set handler function, as a void pointer.">handler</a>)(tContext, unsigned, unsigned, unsigned, unsigned), tContext <a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#a1d6d398295585b08732cc4c611a75363" title="Return the currently set context object, as a void pointer.">context</a>)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00257"></a><span class="lineno">  257</span>&#160;        _SYS_setVector(tID, (<span class="keywordtype">void</span>*) <a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#aaf7df5ac967817e954a0338ca9ac4f49" title="Return the currently set handler function, as a void pointer.">handler</a>, reinterpret_cast&lt;void*&gt;(context));</div>
<div class="line"><a name="l00258"></a><span class="lineno">  258</span>&#160;    }</div>
<div class="line"><a name="l00259"></a><span class="lineno">  259</span>&#160;</div>
<div class="line"><a name="l00272"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#a5a779906aa5c2210967ad6c74ad6cea4">  272</a></span>&#160;    <span class="keywordtype">void</span> <span class="keyword">set</span>(void (*<a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#aaf7df5ac967817e954a0338ca9ac4f49" title="Return the currently set handler function, as a void pointer.">handler</a>)(<span class="keywordtype">void</span>*, unsigned, unsigned, unsigned, unsigned))<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00273"></a><span class="lineno">  273</span>&#160;        _SYS_setVector(tID, (<span class="keywordtype">void</span>*) <a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#aaf7df5ac967817e954a0338ca9ac4f49" title="Return the currently set handler function, as a void pointer.">handler</a>, 0);</div>
<div class="line"><a name="l00274"></a><span class="lineno">  274</span>&#160;    }</div>
<div class="line"><a name="l00275"></a><span class="lineno">  275</span>&#160;</div>
<div class="line"><a name="l00280"></a><span class="lineno">  280</span>&#160;    <span class="keyword">template</span> &lt;<span class="keyword">typename</span> tClass&gt;</div>
<div class="line"><a name="l00281"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#aa8b66ec617fd80d5b131a150aa01e70e">  281</a></span>&#160;    <span class="keywordtype">void</span> <span class="keyword">set</span>(void (tClass::*<a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#aaf7df5ac967817e954a0338ca9ac4f49" title="Return the currently set handler function, as a void pointer.">handler</a>)(unsigned, unsigned, unsigned, unsigned), tClass *cls)<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00282"></a><span class="lineno">  282</span>&#160;        <span class="keyword">union </span>{</div>
<div class="line"><a name="l00283"></a><span class="lineno">  283</span>&#160;            <span class="keywordtype">void</span> *pVoid;</div>
<div class="line"><a name="l00284"></a><span class="lineno">  284</span>&#160;            void (tClass::*pMethod)(unsigned, unsigned, unsigned, unsigned);</div>
<div class="line"><a name="l00285"></a><span class="lineno">  285</span>&#160;        } u;</div>
<div class="line"><a name="l00286"></a><span class="lineno">  286</span>&#160;        u.pMethod = <a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#aaf7df5ac967817e954a0338ca9ac4f49" title="Return the currently set handler function, as a void pointer.">handler</a>;</div>
<div class="line"><a name="l00287"></a><span class="lineno">  287</span>&#160;        _SYS_setVector(tID, u.pVoid, (<span class="keywordtype">void</span>*) cls);</div>
<div class="line"><a name="l00288"></a><span class="lineno">  288</span>&#160;    }</div>
<div class="line"><a name="l00289"></a><span class="lineno">  289</span>&#160;</div>
<div class="line"><a name="l00293"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#aaf7df5ac967817e954a0338ca9ac4f49">  293</a></span>&#160;    <span class="keywordtype">void</span> *<a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#aaf7df5ac967817e954a0338ca9ac4f49" title="Return the currently set handler function, as a void pointer.">handler</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00294"></a><span class="lineno">  294</span>&#160;        <span class="keywordflow">return</span> _SYS_getVectorHandler(tID);</div>
<div class="line"><a name="l00295"></a><span class="lineno">  295</span>&#160;    }</div>
<div class="line"><a name="l00296"></a><span class="lineno">  296</span>&#160;</div>
<div class="line"><a name="l00300"></a><span class="lineno"><a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#a1d6d398295585b08732cc4c611a75363">  300</a></span>&#160;    <span class="keywordtype">void</span> *<a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html#a1d6d398295585b08732cc4c611a75363" title="Return the currently set context object, as a void pointer.">context</a>()<span class="keyword"> const </span>{</div>
<div class="line"><a name="l00301"></a><span class="lineno">  301</span>&#160;        <span class="keywordflow">return</span> _SYS_getVectorContext(tID);</div>
<div class="line"><a name="l00302"></a><span class="lineno">  302</span>&#160;    }</div>
<div class="line"><a name="l00303"></a><span class="lineno">  303</span>&#160;};</div>
<div class="line"><a name="l00304"></a><span class="lineno">  304</span>&#160;</div>
<div class="line"><a name="l00305"></a><span class="lineno">  305</span>&#160;</div>
<div class="line"><a name="l00324"></a><span class="lineno"><a class="code" href="namespace_sifteo_1_1_events.html">  324</a></span>&#160;<span class="keyword">namespace </span>Events {</div>
<div class="line"><a name="l00325"></a><span class="lineno">  325</span>&#160;</div>
<div class="line"><a name="l00326"></a><span class="lineno">  326</span>&#160;    <span class="comment">/*</span></div>
<div class="line"><a name="l00327"></a><span class="lineno">  327</span>&#160;<span class="comment">     * Neighboring events</span></div>
<div class="line"><a name="l00328"></a><span class="lineno">  328</span>&#160;<span class="comment">     */</span></div>
<div class="line"><a name="l00329"></a><span class="lineno">  329</span>&#160;</div>
<div class="line"><a name="l00331"></a><span class="lineno"><a class="code" href="namespace_sifteo_1_1_events.html#ad6b2eed71961c5d7702352666840b647">  331</a></span>&#160;    <span class="keyword">const</span> <a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html" title="Implementation for a single neighbor event vector.">NeighborEventVector&lt;_SYS_NEIGHBOR_ADD&gt;</a>     <a class="code" href="namespace_sifteo_1_1_events.html#ad6b2eed71961c5d7702352666840b647" title="One neighbor connection (cube/side paired with cube/side) has been formed.">neighborAdd</a>;</div>
<div class="line"><a name="l00332"></a><span class="lineno">  332</span>&#160;</div>
<div class="line"><a name="l00334"></a><span class="lineno"><a class="code" href="namespace_sifteo_1_1_events.html#a044cb196d5ccceee3c2834b8cf5e5dc7">  334</a></span>&#160;    <span class="keyword">const</span> <a class="code" href="struct_sifteo_1_1_neighbor_event_vector.html" title="Implementation for a single neighbor event vector.">NeighborEventVector&lt;_SYS_NEIGHBOR_REMOVE&gt;</a>  <a class="code" href="namespace_sifteo_1_1_events.html#a044cb196d5ccceee3c2834b8cf5e5dc7" title="One neighbor connection has been dissolved.">neighborRemove</a>;</div>
<div class="line"><a name="l00335"></a><span class="lineno">  335</span>&#160;</div>
<div class="line"><a name="l00336"></a><span class="lineno">  336</span>&#160;    <span class="comment">/*</span></div>
<div class="line"><a name="l00337"></a><span class="lineno">  337</span>&#160;<span class="comment">     * Cube events</span></div>
<div class="line"><a name="l00338"></a><span class="lineno">  338</span>&#160;<span class="comment">     */</span></div>
<div class="line"><a name="l00339"></a><span class="lineno">  339</span>&#160;</div>
<div class="line"><a name="l00348"></a><span class="lineno"><a class="code" href="namespace_sifteo_1_1_events.html#a0b593de0e58e9aac6016412948371fe7">  348</a></span>&#160;    <span class="keyword">const</span> <a class="code" href="struct_sifteo_1_1_event_vector.html" title="Implementation for a single event vector.">EventVector&lt;_SYS_CUBE_CONNECT&gt;</a>     <a class="code" href="namespace_sifteo_1_1_events.html#a0b593de0e58e9aac6016412948371fe7" title="A new cube has connected and is ready for use.">cubeConnect</a>;</div>
<div class="line"><a name="l00349"></a><span class="lineno">  349</span>&#160;</div>
<div class="line"><a name="l00362"></a><span class="lineno"><a class="code" href="namespace_sifteo_1_1_events.html#ac8d560c099746a69a4aec4a2eac786ae">  362</a></span>&#160;    <span class="keyword">const</span> <a class="code" href="struct_sifteo_1_1_event_vector.html" title="Implementation for a single event vector.">EventVector&lt;_SYS_CUBE_DISCONNECT&gt;</a>  <a class="code" href="namespace_sifteo_1_1_events.html#ac8d560c099746a69a4aec4a2eac786ae" title="A formerly connected cube has been lost.">cubeDisconnect</a>;</div>
<div class="line"><a name="l00363"></a><span class="lineno">  363</span>&#160;</div>
<div class="line"><a name="l00365"></a><span class="lineno"><a class="code" href="namespace_sifteo_1_1_events.html#a7cf2533734727226b0585aeffcc6fc70">  365</a></span>&#160;    <span class="keyword">const</span> <a class="code" href="struct_sifteo_1_1_event_vector.html" title="Implementation for a single event vector.">EventVector&lt;_SYS_CUBE_ASSETDONE&gt;</a>   <a class="code" href="namespace_sifteo_1_1_events.html#a7cf2533734727226b0585aeffcc6fc70" title="The current AssetConfiguration has finished loading on this cube.">cubeAssetDone</a>;</div>
<div class="line"><a name="l00366"></a><span class="lineno">  366</span>&#160;</div>
<div class="line"><a name="l00368"></a><span class="lineno"><a class="code" href="namespace_sifteo_1_1_events.html#a79e3f4a8813fef07c672925e1b15512d">  368</a></span>&#160;    <span class="keyword">const</span> <a class="code" href="struct_sifteo_1_1_event_vector.html" title="Implementation for a single event vector.">EventVector&lt;_SYS_CUBE_ACCELCHANGE&gt;</a> <a class="code" href="namespace_sifteo_1_1_events.html#a79e3f4a8813fef07c672925e1b15512d" title="A cube&#39;s accelerometer state has changed.">cubeAccelChange</a>;</div>
<div class="line"><a name="l00369"></a><span class="lineno">  369</span>&#160;</div>
<div class="line"><a name="l00371"></a><span class="lineno"><a class="code" href="namespace_sifteo_1_1_events.html#a0cdf623ae0e037b6e900be22ec522fdb">  371</a></span>&#160;    <span class="keyword">const</span> <a class="code" href="struct_sifteo_1_1_event_vector.html" title="Implementation for a single event vector.">EventVector&lt;_SYS_CUBE_TOUCH&gt;</a>       <a class="code" href="namespace_sifteo_1_1_events.html#a0cdf623ae0e037b6e900be22ec522fdb" title="A cube&#39;s touch state has changed (touch began or ended).">cubeTouch</a>;</div>
<div class="line"><a name="l00372"></a><span class="lineno">  372</span>&#160;</div>
<div class="line"><a name="l00374"></a><span class="lineno"><a class="code" href="namespace_sifteo_1_1_events.html#a0c4a6b77fc0aff263cdb4f4c5961ce4b">  374</a></span>&#160;    <span class="keyword">const</span> <a class="code" href="struct_sifteo_1_1_event_vector.html" title="Implementation for a single event vector.">EventVector&lt;_SYS_CUBE_BATTERY&gt;</a>     <a class="code" href="namespace_sifteo_1_1_events.html#a0c4a6b77fc0aff263cdb4f4c5961ce4b" title="A cube&#39;s battery level has changed measurably.">cubeBatteryLevelChange</a>;</div>
<div class="line"><a name="l00375"></a><span class="lineno">  375</span>&#160;</div>
<div class="line"><a name="l00388"></a><span class="lineno"><a class="code" href="namespace_sifteo_1_1_events.html#aed6a40b1e3f54c9ac5ad5ecc08f31de0">  388</a></span>&#160;    <span class="keyword">const</span> <a class="code" href="struct_sifteo_1_1_event_vector.html" title="Implementation for a single event vector.">EventVector&lt;_SYS_CUBE_REFRESH&gt;</a>     <a class="code" href="namespace_sifteo_1_1_events.html#aed6a40b1e3f54c9ac5ad5ecc08f31de0" title="The application is responsible for repainting the screen on this cube and checking its installed asse...">cubeRefresh</a>;</div>
<div class="line"><a name="l00389"></a><span class="lineno">  389</span>&#160;</div>
<div class="line"><a name="l00390"></a><span class="lineno">  390</span>&#160;    <span class="comment">/*</span></div>
<div class="line"><a name="l00391"></a><span class="lineno">  391</span>&#160;<span class="comment">     * Base events</span></div>
<div class="line"><a name="l00392"></a><span class="lineno">  392</span>&#160;<span class="comment">     */</span></div>
<div class="line"><a name="l00393"></a><span class="lineno">  393</span>&#160;</div>
<div class="line"><a name="l00395"></a><span class="lineno"><a class="code" href="namespace_sifteo_1_1_events.html#adbb80342067855a5e47316def6cb32b4">  395</a></span>&#160;    <span class="keyword">const</span> <a class="code" href="struct_sifteo_1_1_event_vector.html" title="Implementation for a single event vector.">EventVector&lt;_SYS_BASE_TRACKER&gt;</a>     <a class="code" href="namespace_sifteo_1_1_events.html#adbb80342067855a5e47316def6cb32b4" title="An event generated by Sifteo::AudioTracker.">baseTracker</a>;</div>
<div class="line"><a name="l00396"></a><span class="lineno">  396</span>&#160;</div>
<div class="line"><a name="l00398"></a><span class="lineno"><a class="code" href="namespace_sifteo_1_1_events.html#a763e5b9a11a00a6741c0513200f16a82">  398</a></span>&#160;    <span class="keyword">const</span> <a class="code" href="struct_sifteo_1_1_game_menu_event_vector.html" title="Implementation for the gameMenu event vector.">GameMenuEventVector</a>                <a class="code" href="namespace_sifteo_1_1_events.html#a763e5b9a11a00a6741c0513200f16a82" title="An event generated by an optional custom &quot;game menu&quot; item on the standard pause menu.">gameMenu</a>;</div>
<div class="line"><a name="l00399"></a><span class="lineno">  399</span>&#160;</div>
<div class="line"><a name="l00401"></a><span class="lineno"><a class="code" href="namespace_sifteo_1_1_events.html#a92bfd19cdd0b0976841887a8885acf01">  401</a></span>&#160;    <span class="keyword">const</span> <a class="code" href="struct_sifteo_1_1_event_vector.html" title="Implementation for a single event vector.">EventVector&lt;_SYS_BASE_VOLUME_DELETE&gt;</a>  <a class="code" href="namespace_sifteo_1_1_events.html#a92bfd19cdd0b0976841887a8885acf01" title="A filesystem Volume was deleted.">volumeDelete</a>;</div>
<div class="line"><a name="l00402"></a><span class="lineno">  402</span>&#160;</div>
<div class="line"><a name="l00404"></a><span class="lineno"><a class="code" href="namespace_sifteo_1_1_events.html#a9a7c75db7acade727b784040b012061e">  404</a></span>&#160;    <span class="keyword">const</span> <a class="code" href="struct_sifteo_1_1_event_vector.html" title="Implementation for a single event vector.">EventVector&lt;_SYS_BASE_VOLUME_COMMIT&gt;</a>  <a class="code" href="namespace_sifteo_1_1_events.html#a9a7c75db7acade727b784040b012061e" title="A filesystem Volume was committed and is now available to read.">volumeCommit</a>;</div>
<div class="line"><a name="l00405"></a><span class="lineno">  405</span>&#160;</div>
<div class="line"><a name="l00406"></a><span class="lineno">  406</span>&#160;};  <span class="comment">// namespace Events</span></div>
<div class="line"><a name="l00407"></a><span class="lineno">  407</span>&#160;</div>
<div class="line"><a name="l00412"></a><span class="lineno">  412</span>&#160;};  <span class="comment">// namespace Sifteo</span></div>
</div><!-- fragment --></div><!-- contents -->
<!-- HTML footer for doxygen 1.8.3.1-->
<!-- start footer part -->
    <hr class="footer"/>
    <address class="footer">
        <p><a href="http://sifteo.com">Sifteo</a> SDK v1.0.0 <small>(see <a href="https://developers.sifteo.com/sifteosdk">all versions</a>)</small></p>
        <p>Last updated Wed Mar 27 2013, by <a href="http://www.stack.nl/~dimitri/doxygen">Doxygen</a></p>
    </address>
</body>
</html>
